<?php if ($flag == 1){ ?>
<div id="box_cart" class="box_order">
<?php echo form_open('carts/cart'); ?>

<table cellpadding="6" cellspacing="1" style="width:100%" border="0" id="cart_content">
    <tr>  
      <th >Món</th>
      <th class="col_qty">S.lượng</th>  
      <th class="col_price" style="text-align:center" >Giá</th>
      <th class="col_delete">Xóa</th>
    </tr>
<?php $i = 1; ?>
<?php foreach ($this->cart->contents() as $items): ?>
	<?php echo form_hidden($i.'[rowid]', $items['rowid']);  ?>
	<tr class="<?php echo $items['rowid']; ?>">	  
            <td>
                  <?php echo $items['name']; ?>			
            </td>
            <td id="qty_<?php echo $items['rowid'] ?>" class="col_qty"><input type="text" name="<?php echo $items['rowid'] ?>" value="<?php echo $items['qty'] ?>" size="1"/></td>	 
            <td class="col_price" style="text-align:right"><?php echo number_format($items['subtotal']); ?> Đ</td>
            <td class="col_delete"><div class="delete_cart" rowid="<?php echo $items['rowid']; ?>"><img src="<?php echo base_url(); ?>content/images/delete_16x16.gif"/></div></td>
	</tr>

<?php $i++; ?>

<?php endforeach; ?>
</table>
<div class="tong_tien"><strong>Tổng:</strong><?php echo ' '.number_format($this->cart->total()); ?> Đ</div>

<input class="button_cart" type="submit" value="Cập nhật"/>
</div>
<?php }  else {?>
<div></div>
<?php ?>
<?php } ?>
